Add iOS pane action workflows - #429
Conversation
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
🔵 Needs a closer look
It is R3 iOS consequential-action UI and remote action-session presentation work that should receive independent human review despite tests covering the primary flows.
Pull request overview
This PR wires the iOS “pane actions” surface into the production app shell so consequential remote lifecycle workflows (merge, create PR, rename, close/cleanup) and ritual actions are executed through the same RemoteActionStore + ActionSheetView presentation path, with explicit stop vs cleanup confirmations and stale/in-flight disabling.
Changes:
- Added
RemoteActionStore.canStartAction(onPane:)and an initial non-dismissable “Waiting for the host…” progress presentation for blocked starts. - Extended
RemoteActionPresentationwith a stableactionLabeland added aPaneAction.presentationLabelmapping, then updated iOS Action Sheet rendering to use it. - Expanded iOS pane controls (menu, cleanup confirmation, file browser, rituals menu) and added/updated fixtures + unit/UI tests to cover the production composition path.
File summaries
| File | Description |
|---|---|
| native/ios/PsycheCore/Tests/PsycheCoreTests/RemoteActionStoreTests.swift | Adds coverage for canStartAction gating and “blocked start shows progress until host replies”. |
| native/ios/PsycheCore/Tests/PsycheCoreTests/RemoteActionPresentationTests.swift | Asserts actionLabel behavior and verifies progress(...) defaults (label + non-dismissable). |
| native/ios/PsycheCore/Sources/PsycheCore/State/RemoteActionStore.swift | Introduces canStartAction and sets an initial progress presentation immediately after marking a pane busy. |
| native/ios/PsycheCore/Sources/PsycheCore/State/RemoteActionPresentation.swift | Adds actionLabel, a progress(...) factory, and centralizes action label mapping via PaneAction.presentationLabel. |
| native/ios/PsycheCore/Sources/PsycheCore/Fixtures/WorkspaceFixtures.swift | Extends workspace fixtures to include per-project ritual publication snapshots for menu/UI coverage. |
| native/ios/PsycheCore/Sources/PsycheCore/Fixtures/FixtureControlRequests.swift | Adds deterministic fixture support for remote pane action start/respond flows and ritual launching to exercise production wiring. |
| native/ios/PsycheApp/UnitTests/CreatePaneFormTests.swift | Adds unit assertions for cleanup confirmation semantics, stale/busy disabling rules, and ritual empty/unavailable messaging. |
| native/ios/PsycheApp/UnitTests/ActionSheetPresentationTests.swift | Adds fixture-based tests ensuring rename/cleanup actions produce expected production Action Sheet presentations. |
| native/ios/PsycheApp/Tests/PsycheAppUITests/PsycheAppUITests.swift | Updates UI coverage to verify the pane actions menu lists lifecycle + rituals and that cleanup routes into the remote close workflow. |
| native/ios/PsycheApp/Sources/PsycheApp/Views/PaneControls.swift | Expands pane actions menu (merge/create PR/rename/files/rituals/stop/cleanup), adds cleanup confirmation, and introduces stale/busy disabling logic. |
| native/ios/PsycheApp/Sources/PsycheApp/Views/CreatePaneForm.swift | Adds cleanup confirmation copy helpers (CleanupPaneConfirmation) emphasizing consequences before destructive continuation. |
| native/ios/PsycheApp/Sources/PsycheApp/Views/ActionSheetView.swift | Refactors section ordering and uses presentation.actionLabel for consistent headers while keeping interactive-dismiss guarding. |
| native/ios/PsycheApp/Sources/PsycheApp/Views/ActionSheetPresentation.swift | Switches action label lookup to PaneAction.presentationLabel and makes ActionSheetSection Hashable for ForEach ordering. |
| native/ios/PsycheApp/Sources/PsycheApp/CockpitView.swift | Presents ActionSheetView from the production cockpit shell whenever RemoteActionStore.presentation is non-nil, dismissing via store.dismiss(). |
Review details
- Files reviewed: 14/14 changed files
- Comments generated: 0
- Review effort level: Lite
💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
|
Independent R3 review of all14 changed files at94a845586a416a9a1c406331a225bfa12644a551 against5dd2a6bdbdfbaddf8623f8d0cff312c943d2988c found three actionable P2 defects; no merge recommended:
These are source-path findings, distinct from physical-device acceptance. Quality is canceled and the required aggregate failed at this head. Neither #200 nor the Beads-owned #218 acceptance is established by these fixture/simulator results. Uncommitted author-worktree changes were excluded and left untouched. Current fixes must earn a fresh exact-head independent review and terminal required checks. |
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Outcome
Refs #218 and #200.
Adds the native iOS pane action menu wiring for remote merge / create-PR / rename / close flows, plus distinct native stop and cleanup confirmations, so mobile pane actions now surface guarded lifecycle choices through production UI instead of dead-end placeholders.
Scope and boundaries
RemoteActionStore+ActionSheetViewinto the production iOS app shell so remote pane actions present visible progress, interactive prompts, and terminal results.PaneControlsMenuto expose merge, create pull request, rename, browse files, rituals, stop, and close-and-cleanup actions with stale / in-flight disabling.PaneAction.CLOSE; the native cleanup confirmation only gates entry into the existing close workflow.Risk class
Review
docs/ROADMAP.md,docs/SUPPORT-MATRIX.md,docs/RELEASE-ACCEPTANCE.md, anddocs/CONTRIBUTOR-SAFETY.mdbefore making availability or production-readiness claims.Validation and evidence
Acceptance mapping:
Stop and cleanup are visually / semantically distinct:
CreatePaneFormTests.testStopAndCleanupMenuActionsStayDistinctandPsycheAppUITests.testPaneActionsMenuListsRemoteLifecycleAndRitualActionsDestructive consequence text comes before the action button:
ActionSheetPresentationTests.testSectionOrderKeepsContextBeforeContentAndControls,CreatePaneFormTests.testStopConfirmationSaysTheWorkSurvives, andCreatePaneFormTests.testCleanupConfirmationExplainsTheChoicesBeforeContinuingStale or already-running actions are disabled:
CreatePaneFormTests.testPaneControlsDisableHostActionsForStaleOrBusyState,RemoteActionStoreTests.testDuplicateResponseTapSendsExactlyOnceWhileFirstResponseIsBlocked,RemoteActionStoreTests.testSecondStartWhileFirstIsBlockedSendsNothingAndPreservesFirstWorkflow, andRemoteActionStoreTests.testBlockedStartShowsVisibleProgressUntilTheHostRepliesResult / error / progress stay visible:
RemoteActionStoreTests.testBlockedStartShowsVisibleProgressUntilTheHostReplies,RemoteActionStoreTests.testTransportFailureAfterInputPreservesRecoveryTextAndClearsBusy,RemoteActionStoreTests.testReturnedProtocolErrorBecomesVisibleError,ActionSheetPresentationTests.testFixtureRenameActionProducesInteractiveInputPresentation, andActionSheetPresentationTests.testFixtureCleanupActionProducesChoicePresentationI added or identified focused coverage for the changed behavior.
I ran the owning-surface checks and recorded their exact results.
Required checks are terminal on the exact head SHA, or this PR remains draft.
I did not treat test counts, source presence, hosted compilation, or simulator success as proof of an unobserved production path.
I documented rollback, migration, and recovery implications where applicable.
Generated outputs
Security and privacy
Review focus
native/ios/PsycheApp/Sources/PsycheApp/Views/PaneControls.swift,CockpitView.swift, andActionSheetView.swiftfor production composition, disabled-state gating, and confirmation semantics.native/ios/PsycheCore/Sources/PsycheCore/State/RemoteActionStore.swift,RemoteActionPresentation.swift, and the fixture/test updates for visible progress, stale-response safety, and deterministic mobile action coverage.Release and support impact
This is R3 iOS work touching consequential action UI and action-session presentation. It requires independent review before merge; do not merge on my approval alone.